package com.fingard.dsp.bank.reqrespobj.elecbillquery.detail;

import java.util.ArrayList;
import java.util.List;

import com.fingard.xml.XmlTextWriter;

/**
 * Created by F on 2019/5/21.
 */
public class RetAtsB009DrawBillQryProtocolDetail {

    public String protocolNo;
    public String startDate;
    public String protocolAmount;
    public String protocolItem;
    //单位 0:天 1:月
    public String itemUnit;
    public String protocolState;

    public List<RetAtsB009DrawBillQryTransDetail> list =
            new ArrayList<RetAtsB009DrawBillQryTransDetail>();

    public void writeDetail(XmlTextWriter retXmlWriter, RetAtsB009DrawBillQryProtocolDetail protocolDetail) {
        retXmlWriter.writeStartElement("ProtocolRecord");
        retXmlWriter.writeElementString("ProtocolNo",protocolDetail.protocolNo);
        retXmlWriter.writeElementString("StartDate",protocolDetail.startDate);
        retXmlWriter.writeElementString("ProtocolAmount",protocolDetail.protocolAmount);
        retXmlWriter.writeElementString("ProtocolItem",protocolDetail.protocolItem);
        retXmlWriter.writeElementString("ItemUnit",protocolDetail.itemUnit);
        retXmlWriter.writeElementString("ProtocolState",protocolDetail.protocolState);
        if(list!=null&&list.size()!=0){
            for(RetAtsB009DrawBillQryTransDetail detail:list){
                detail.writeDetail(retXmlWriter,detail);
            }
        }
        retXmlWriter.writeEndElement();
    }
    
    
}
